'''
Created on 05/04/2013

@author: tsantana
'''

from google.appengine.ext import webapp
from google.appengine.ext.webapp import util
#from google.appengine.ext.webapp import template
#from google.appengine.dist import use_library
#use_library('django', '1.0')

from thilux_request_handlers import MainPage, MainPageTest, AddUserPage, AddUserAction, SignIn, UsersPage, LogOut, GetTest, AddDepartment, AddDepartmentAction, AddPosition, AddPositionAction, AddEmployee
import create_data

'''
Main dummy handler
'''

class DummyHundler(webapp.RequestHandler):
    def get(self, q):
        self.response.out.write('thilux Systems -> Dummy')
        
    #thilux_pages.get_page(pagename)
        
'''
URL mapper - START
'''
        
def main():
    application = webapp.WSGIApplication([(r'/()', MainPage), 
                                          (r'/(main$)', MainPageTest),
                                          (r'/(adduser$)', AddUserPage),
                                          ('/adduseraction', AddUserAction),
                                          ('/signin', SignIn),
                                          (r'/(users$)', UsersPage),
                                          (r'/(logout$)', LogOut),
                                          (r'/(gettest$)', GetTest),
                                          (r'/(adddepartment$)', AddDepartment),
                                          ('/adddepartmentaction', AddDepartmentAction),
                                          (r'/(addposition$)', AddPosition),
                                          ('/addpositionaction', AddPositionAction),
                                          ('/addemployee', AddEmployee)], debug=True)
    util.run_wsgi_app(application)
    create_data.start_data_creation()
    
main()